<%--
  Created by IntelliJ IDEA.
  User: 26098
  Date: 2023/12/31
  Time: 10:51
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<!DOCTYPE html>
<html>
<head>
    <!-- 导入资源 -->
    <%@ include file="resource.jsp"%>
</head>
<body>

<div class="container" style="margin: 24px auto;">
    <div class="row">
        <div>
            <h2 class="center">User Signin</h2>
            <!-- 登录成功 显示如下信息 -->
            <c:if test="${sessionScope.userVo.id>0}">
                <h4>${sessionScope.userVo.username} Signin Success! Go to
                    <a href="index.jsp" class="btn btn-primary">Home</a> or
                    <a href="cart.jsp" class="btn btn-primary">Shopping Cart</a> .
                </h4>
            </c:if>
            <!-- 登录失败 显示如下信息 -->
            <c:if test="${sessionScope.userVo==null||sessionScope.userVo.id==0}">
                <c:forEach var="str" items='${requestScope.resultVo.list}'
                           varStatus="varStatus">
                    <p class="alert alert-danger">${varStatus.count}. ${str}</p>
                </c:forEach>
                <a href="signin.jsp" class="btn btn-primary">Back to Signin</a>
            </c:if>
        </div>
    </div>
</div>

</body>
</html>
